<template lang="html">
  <panel title="理财精选">
    <section class="content">
      <dl class="item" v-for="item in items" :key='item.title'>
        <dt>{{item.title}}<span>{{item.sub}}</span></dt>
        <dd>{{item.rate}}</dd>
        <dd>{{item.text}}</dd>
      </dl>
    </section>
  </panel>
</template>

<script>
import Panel from '../core/panel.vue'
export default {
  components:{
    Panel
  },
  data(){
    return {
      items:[
        {
          title:'定期理财',
          sub:"理财首选",
          rate:"50%",
          text:"历史年回报率"
        },
        {
          title:'定期理财',
          sub:"理财首选",
          rate:"50%",
          text:"历史年回报率"
        },
        {
          title:'定期理财',
          sub:"理财首选",
          rate:"50%",
          text:"历史年回报率"
        },
        {
          title:'定期理财',
          sub:"理财首选",
          rate:"50%",
          text:"历史年回报率"
        }
      ]
    }
  }
}
</script>

<style lang="scss" scoped>
@import '../../css/element.scss';
.panel{
  .content{
    @include flex(row);
    justify-content: space-around;
    box-sizing: border-box;
    &:after{
      content: " ";
width: 100%;
height: 0;
      display: block;
      position: relative;
      top: -208px;

      border-bottom: 1px solid #eee;
    }
    .item{
      position: relative;
      width: 50%;
      box-sizing: border-box;
      &:after{
        content:" ";
        width: 1px;
        height: 136px;
        display: block;
        position: absolute;
        top:50%;
        right: 0;
        margin-top: -68px;
        border-right: 1px solid #eee;

      }
      &:nth-child(2n){
        &:after{
          display:none;
        }
      }
      padding: 34px 16px;
      dt{
        font-size: 30px;
        line-height: 42px;
        color:#333;

        span{
          font-size: 22px;
          color:#ff5155;
          border: 1px solid #ff5155;
          padding: 0 8px;
          vertical-align: 1px;
          margin-left:2px;
        }
      }
      dd:nth-child(2){
        font-weight: 700;
        font-size: 44px;
        height: 58px;
        line-height: 58px;
        color: #FF5155;
        white-space: nowrap;
        text-overflow: ellipsis;
        overflow: hidden;
      }
      dd:nth-child(3){
        font-size: 24px;
        height: 34px;
        line-height: 34px;
        color: #999;
        white-space: nowrap;
        text-overflow: ellipsis;
        overflow: hidden;
      }
    }
  }
}
</style>
